/*
Michelle Allendoerfer, Amanda Murdie, and Ryan M. Welch
Path of the Boomerang Replication File
*/

use "C:\Users\rwelch\Dropbox\Research\AllMurWel\AllMurWel_ReplicationData.dta", clear
cd "C:\Users\rwelch\Dropbox\Research\AllMurWel"

*set more off
set more off

*set seed for replicability
set seed 32605

*Main Model
*Tables 2 & 3 
medeff(logit thirdpartysanctionshumandi lagphysint humanrightsevents   polity2 ross_oil_netexpc WB_tradegdp  lnreportcount) (regress physint lagphysint humanrightsevents thirdpartysanctionshumandi polity2 WB_lnpop WB_lngdp internationalwar civilwar lnreportcount) if physint!=8,  treat(humanrightsevents) mediate(thirdpartysanctionshumandi) sims(1000)  vce(robust)

*Appendix
*Table A1: Gender Empowerment Robustness
medeff(logit thirdpartysanctionshumandi lagphysint humanrightsevents polity2 ross_oil_netexpc WB_tradegdp lnreportcount v2x_gender) (regress physint lagphysint humanrightsevents thirdpartysanctionshumandi polity2 WB_lnpop WB_lngdp internationalwar civilwar lnreportcount v2x_gender) if physint!=8,  treat(humanrightsevents) mediate(thirdpartysanctionshumandi) sims(1000)  vce(robust)

*Table A2: Moderation Model Robustness
gen interact = humanrightsevents * thirdpartysanctionshumandi
regress physint lagphysint humanrightsevents thirdpartysanctionshumandi interact polity2 WB_lnpop WB_lngdp internationalwar civilwar lnreportcount, vce(r)


*Table A3: CINC Robustness
medeff(logit thirdpartysanctionshumandi lagphysint humanrightsevents   cinc polity2 ross_oil_netexpc WB_tradegdp  lnreportcount) (regress physint lagphysint humanrightsevents thirdpartysanctionshumandi polity2 WB_lnpop WB_lngdp internationalwar civilwar lnreportcount) if physint!=8,  treat(humanrightsevents) mediate(thirdpartysanctionshumandi) sims(1000)  vce(robust)

*Table A4: Only Imposed Sanctions Included in Third-party Action Variable
medeff(logit thirdpartyIMPOSEDdi lagphysint humanrightsevents   polity2 ross_oil_netexpc WB_tradegdp  lnreportcount) (regress physint lagphysint humanrightsevents thirdpartyIMPOSEDdi polity2 WB_lnpop WB_lngdp internationalwar civilwar lnreportcount) if physint!=8,  treat(humanrightsevents) mediate(thirdpartyIMPOSEDdi) sims(1000)  vce(robust)


*Table A5: Only Imposed Sanctions Included in Third-party Action Variable, CINC Score
medeff(logit thirdpartyIMPOSEDdi lagphysint humanrightsevents   cinc polity2 ross_oil_netexpc WB_tradegdp  lnreportcount) (regress physint lagphysint humanrightsevents thirdpartyIMPOSEDdi polity2 WB_lnpop WB_lngdp internationalwar civilwar lnreportcount) if physint!=8,  treat(humanrightsevents) mediate(thirdpartyIMPOSEDdi) sims(1000)  vce(robust)
